// 初始化处理template数据
import React from "react";

export default function processTemplate(template) {
    template['contopiniongrid'].items.unshift({
        itemtype: 'customer',
        dataIndex: "numberindex",
        label: this.state.json['cm6011-000152'],
        visible: true,
        fixed: 'left',
        width: '80px',
        attrcode: 'numberindex'
    });
    template['contopiniongrid'].items.forEach(item => {
        if (item.attrcode === 'conttype' || item.attrcode === 'pk_psnjob.pk_psndoc.code' || item.attrcode === 'pk_psnjob.pk_psndoc.name') {
            item.fixed = 'left';
        }
    });
    template['contopinionadd'].items.forEach(item => {
        if (item.attrcode === 'psncode' || item.attrcode === 'pk_psndoc') {
            item.fixed = 'left';
        }
    });
    return template
}
